using System;
using System.Collections.Generic;
using Table.DataModel;
namespace Table.Dao
{
    public class TablePerformanceSettingConfigDao:DaoBase<TablePerformanceSettingConfig>
    {
        public override string GetFileName()
        {
            return "TablePerformanceSettingConfig.csv";
        }
        protected override TablePerformanceSettingConfig ParseRowData(string[] rowData)
        {
            return null;
        }
        protected override void InitTableRowData(TableFileReader dfr)
        {
            for (int i = 0; i < 5; ++i)
            {
                dfr.ReadRow();
            }
            TablePerformanceSettingConfig.highQulityShadow = dfr.ReadRow()[1];
            TablePerformanceSettingConfig.midiumQulityShadow = dfr.ReadRow()[1];
            TablePerformanceSettingConfig.lowQulityShadow = dfr.ReadRow()[1];
            TablePerformanceSettingConfig.highendDevice = dfr.ReadRow()[1];
            TablePerformanceSettingConfig.midiumhendDevice = dfr.ReadRow()[1];
            TablePerformanceSettingConfig.lowendDevice = dfr.ReadRow()[1];
            TablePerformanceSettingConfig.pingThresold = ParseData<int>(dfr.ReadRow()[1]);
            TablePerformanceSettingConfig.batteryThresold = ParseData<float>(dfr.ReadRow()[1]);
        }
    }
}
